From aa16f8e09b8a9ba332e2eed2b789e3f6b1e09eae Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Mon, 12 Mar 2007 02:51:40 +0000 Subject: [PATCH] Don't crash if active_tips_data is NULL. (#382904, Li Yuan) 2007-03-11 Matthias Clasen * gtk/gtktooltips.c (gtk_tooltips_get_info_from_tip_window): Don't crash if active_tips_data is NULL. (#382904, Li Yuan) 2 svn path=/trunk/; revision=17483 --- ChangeLog | 5 +++++ gtk/gtktooltips.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 746361fa8a..42f2353ee1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-03-11 Matthias Clasen + + * gtk/gtktooltips.c (gtk_tooltips_get_info_from_tip_window): + Don't crash if active_tips_data is NULL. (#382904, Li Yuan) + 2007-03-11 Matthias Clasen * gtk/gtktextview.c (gtk_text_view_set_buffer): Set first_para_mark diff --git a/gtk/gtktooltips.c b/gtk/gtktooltips.c index 458f9e4109..bb41f14325 100644 --- a/gtk/gtktooltips.c +++ b/gtk/gtktooltips.c @@ -779,7 +779,7 @@ gtk_tooltips_get_info_from_tip_window (GtkWindow *tip_window, if (tooltips) *tooltips = current_tooltips; if (current_widget) - *current_widget = has_tips ? current_tooltips->active_tips_data->widget : NULL; + *current_widget = (has_tips && current_tooltips->active_tips_data) ? current_tooltips->active_tips_data->widget : NULL; return has_tips; } -- 2.30.2